package com.xuelang.pipeline.infrastructure.pipeline.converter;

import com.xuelang.pipeline.domain.pipeline.DeploymentUnit;
import com.xuelang.pipeline.infrastructure.pipeline.dataobject.DeploymentUnitDO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

/**
 * <p>部署单DO转换器</p>
 *
 * @author : yixin.lys
 * @date : 2024-06-25 17:12
 **/
@Mapper
public interface DeploymentUnitToDOConverter {

    DeploymentUnitToDOConverter INSTANCE = Mappers.getMapper(DeploymentUnitToDOConverter.class);

    /**
     * 从DO转换
     * @param target
     * @return
     */
    DeploymentUnit fromDO(DeploymentUnitDO target);

    /**
     * 转换为DO
     * @param target
     * @return
     */
    DeploymentUnitDO toDO(DeploymentUnit target);
    
}
